Hi,
It isn't clear to me what you are asking. Are you trying to do this from your own C# application or from Mach3 or KMotionCNC?
But you might handle it from a KFLOP C Program. For example you might use a Virtual IO bit (#48) to select the machine mode mode you are in. 1=mill 0=plasma. You could then create User Buttons or M Codes to change mode. The M3,M4,M5,Spindle C programs could then test the current mode and do the appropriate thing.
Regards TK
Group: DynoMotion |
Message: 5275 |
From: roa_controls |
Date: 6/20/2012 |
Subject: Re: Mcode Bit Assignment |
Thanks Ray,
The .Interpreter.SetMcodeAction() method is not exposed in my 4.28 build of KMotion_dotNet.dll. I did a search in the source and it's not there. I do see it 4.29. I have a custom build to expose COM to VB6 so I'll need to modify 4.29 and rebuild it. For not I'll just activate/deactivate my tools before/after I execute the ngc file. Unless someone has a better idea. Maybe a C program to interpret the Mcodes and set the bits?
Shannon
--- In DynoMotion@yahoogroups.com, "himykabibble" <jagboy@...> wrote:
>
> It's kinda buried:
>
> KM_Controller.CoordMotion.Interpreter.SetMcodeAction();
>
> For example:
>
> KM_Controller.CoordMotion.Interpreter.SetMcodeAction(3, MCODE_TYPE.M_Action_SetTwoBits, KMIO["SpindleCW"].ID, 1, KMIO["SpindleCCW"].ID, 0, 0, "SpindleCW");
>
> Regards,
> Ray L.
>
> --- In DynoMotion@yahoogroups.com, "roa_controls" <sdavenport.roa@> wrote:
> >
> > I see some dialog about this in the last couple of days... Guess I should have done a little searching on this topic first. I'm using 4.28 and don't see SetMcodeAction or GetMcodeAction.
> >
> > --- In DynoMotion@yahoogroups.com, "roa_controls" <sdavenport.roa@> wrote:
> > >
> > > My machine is multi function and depending on which mode is selected I would like to run different tools with the same gcode.
> > > Plasma M3 to set bit 152
> > > Mill M3 to set bit 153
> > >
> > > How can I programmatically assign a bit to an mcode before executing the ngc file?
> > >
> >
>
|
|
Group: DynoMotion |
Message: 5276 |
From: roa_controls |
Date: 6/20/2012 |
Subject: Re: Mcode Bit Assignment |
Tom,
I need to change the bit that M3, M4, M5 controls form my VB6 program. I'll try it with a C program.
Shannon
--- In DynoMotion@yahoogroups.com, Tom Kerekes <tk@...> wrote:
>
> Hi,
>
> It isn't clear to me what you are asking. Are you trying to do this from your own C# application or from Mach3 or KMotionCNC?
>
> But you might handle it from a KFLOP C Program. For example you might use a Virtual IO bit (#48) to select the machine mode mode you are in. 1=mill 0=plasma. You could then create User Buttons or M Codes to change mode. The M3,M4,M5,Spindle C programs could then test the current mode and do the appropriate thing.
>
> Regards
> TK
>
>
>
> ________________________________
> From: roa_controls <sdavenport.roa@...>
> To: DynoMotion@yahoogroups.com
> Sent: Wednesday, June 20, 2012 7:40 AM
> Subject: [DynoMotion] Re: Mcode Bit Assignment
>
>
>
> Â
> I see some dialog about this in the last couple of days... Guess I should have done a little searching on this topic first. I'm using 4.28 and don't see SetMcodeAction or GetMcodeAction.
>
> --- In DynoMotion@yahoogroups.com, "roa_controls" <sdavenport.roa@> wrote:
> >
> > My machine is multi function and depending on which mode is selected I would like to run different tools with the same gcode.
> > Plasma M3 to set bit 152
> > Mill M3 to set bit 153
> >
> > How can I programmatically assign a bit to an mcode before executing the ngc file?
> >
>
|
|
| |